<%@ Page Language="C#" AutoEventWireup="true" CodeFile="explore.aspx.cs" Inherits="Views_Grurrah_explore" MasterPageFile="~/Views/layouts/default_w_sidebar.master" %>

<%@ Register Assembly="Gaia.WebWidgets" Namespace="Gaia.WebWidgets" TagPrefix="gaia" %>
<%@ Register Assembly="Grr" Namespace="Grr.Web.WebControls" TagPrefix="grurrah" %>
<%@ Import Namespace="Grr.Models" %>

<asp:Content ContentPlaceHolderID="TitleType" runat="server">Explore</asp:Content>
<asp:Content ContentPlaceHolderID="TitleText" runat="server"></asp:Content>

<asp:Content ContentPlaceHolderID="MainContent" runat="server">
    
    <div id="popular-container" class="explore-container">
        <h2>Popular Grurrahs</h2>
        <gaia:Panel ID="PopularPanel" Visible="true" runat="server">
            <ol start="<%= CurrentPopularResultsIndex + 1 %>">
                <% foreach (SearchMatch result in Popular.Matches) {  %>
                    <li>
                        <a href="<%= ResolveUrl (result.Url) %>"><%= result.Title %></a>:
                        <%= result.Description %>
                    </li>
                <% } %>
            </ol>
        </gaia:Panel>
        <div class="results-paging-buttons">
            <gaia:LinkButton ID="PopularPrevButton" Visible="false" Text="[Prev]" runat="server" OnClick="PopularPrevButton_Click"></gaia:LinkButton>
            <gaia:LinkButton ID="PopularNextButton" Visible="false" Text="[Next]" runat="server" OnClick="PopularNextButton_Click"></gaia:LinkButton>
        </div>
    </div>
    <div id="recent-container" class="explore-container">
        <h2>Recently Created Grurrahs</h2>
        <gaia:Panel ID="RecentPanel" Visible="true" runat="server">
            <ol start="<%= CurrentRecentResultsIndex + 1 %>">
                <% foreach (SearchMatch result in Recent.Matches) {  %>
                    <li>
                        <a href="<%= ResolveUrl (result.Url) %>"><%= result.Title %></a>:
                        <%= result.Description %>
                    </li>
                <% } %>
            </ol>
        </gaia:Panel>
        <div class="results-paging-buttons">
            <gaia:LinkButton ID="RecentPrevButton" Visible="false" Text="[Prev]" runat="server" OnClick="RecentPrevButton_Click"></gaia:LinkButton>
            <gaia:LinkButton ID="RecentNextButton" Visible="false" Text="[Next]" runat="server" OnClick="RecentNextButton_Click"></gaia:LinkButton>
        </div>
    </div>
    <div id="tag-cloud-container" class="explore-container">
        <h2>Tags</h2>
        <grurrah:TagCloud ID="tag_cloud" CssClass="tag-cloud" runat="server" />
        <div style="clear:both;"></div>
    </div>
</asp:Content>

